from typing import Optional, List


class Solution:
    def longestPalindrome(self, s: str) -> str:
        pass

    def fun(self, s):
        s1 = s + s
        if s in s1[1:-1]:
            return True
